php forum
php mysql forum
php mysql smarty
 
Page 1 of 3 1 2 3 >
Topic Options
#314836 - 07/20/07 12:54 PM [7.2.1] - Hop to as a popup menu
sirdude Offline
Enthusiast

Registered: 11/08/03
Posts: 490
Loc: SoCal
Had a couple requests for this and threw it together. This essentially removes the 'Hop to:' pulldown and 'Go' button functionality from the bottom of showflat and postlist and makes it a popup menu.

Before pic:



After pic (on a different board of course - i can't modify ubbcentral!! laugh



Instructions:

Just read the Readme.txt (attached) and do it.

You can fiddle with '$jumpbox = $html -> hop_to(40);' and change the number 40 to your liking. The number 40 signifies the number of characters to display for forum/sub-forum(s), before using the '...' continuation. you'd do this in 2 places. showflat.inc.php and postlist.inc.php. no need to fiddle with the ubbthreads.inc.php class, as that is just the default over there.

This allows for loooong stuff to be trimmed and then the menu doesn't go bonkers width wise..

Good luck.

Notes:

1. you can easily move this menu to the right (over by the pager), but simply editing the tpls. Keep in mind, if there is no right side portal, you might have the popup to wide to fit on screen.
2. you can also duplicate the menus that are on top to down below as well.
3. you may want to edit the language for 'Hop to:' to 'Hop to' to get rid of the colon, if you are anal about it wink

example:



once again, it's a simple .tpl mod. I've done it, but am time pressed to post here. I'm quite sure someone could take this example and post those mods as a part of this thread though wink

we have enough tpl gooooos, to be able to slice and dice as needed.

Good luck wink


Attachments
2459-ReadMe.txt (28 downloads)
Description: Prolly want to read it ;)




Edited by sirdude (08/21/07 11:39 PM)
Edit Reason: Updated for 7.2.1
_________________________

Top
#314839 - 07/20/07 08:15 PM Re: [7.2] - Hop to as a popup menu [Re: sirdude]
Gizmo Offline

Wizard

Registered: 01/10/00
Posts: 5354
Loc: Portland, OR, USA
Lookin good wink
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design & Development President
UBB.Threads: My UBBSkins, UBB.Sitemaps

Top
#314845 - 07/21/07 07:13 AM Re: [7.2] - Hop to as a popup menu [Re: Gizmo]
Rose Offline
Power User

Registered: 09/29/06
Posts: 76
Thanks SD .. going to apply it now. smile

Top
#314846 - 07/21/07 07:44 AM Re: [7.2] - Hop to as a popup menu [Re: Rose]
Rose Offline
Power User

Registered: 09/29/06
Posts: 76
SD, I got this error:

Fatal error: Call to undefined function: hop_to() in /xxx/xxx/xxx-www/forums/scripts/postlist.inc.php on line 487

This is the line that has the following code:

Code:
$jumpbox = $html -> hop_to(40); 


Any ideas?


Top
#314850 - 07/21/07 10:26 AM Re: [7.2] - Hop to as a popup menu [Re: Rose]
sirdude Offline
Enthusiast

Registered: 11/08/03
Posts: 490
Loc: SoCal
hop_to function is added new in ubbthreads.inc.php. that's step 1, so either you didn't do that step or you didn't upload the new ubbthreads.inc.php..

:2c:
_________________________

Top
#314852 - 07/21/07 11:48 AM Re: [7.2] - Hop to as a popup menu [Re: sirdude]
Rose Offline
Power User

Registered: 09/29/06
Posts: 76
Ok, will try again. smile

Top
#314857 - 07/21/07 05:51 PM Re: [7.2] - Hop to as a popup menu [Re: sirdude]
Mike G Offline
Newbie

Registered: 05/28/07
Posts: 11
Originally Posted By: sirdude
hop_to function is added new in ubbthreads.inc.php. that's step 1, so either you didn't do that step or you didn't upload the new ubbthreads.inc.php..

:2c:


I got the same thing last night and figured I applied the mod incorrectly. So I tried again today and got the same action.

On the ubbthreads.inc.php modifications, you basically add your function to the bottom of the file just above the closing "?>" and that pretty much does it?

Get this when clicking on the forum:

Fatal error: Call to undefined method html::hop_to() in /usr/home/dunsire/ubb7test/scripts/postlist.inc.php on line 487

Get this when clicking on the last topic:

Fatal error: Call to undefined method html::hop_to() in /usr/home/dunsire/ubb7test/scripts/showflat.inc.php on line 528

Top
#314864 - 07/21/07 10:08 PM Re: [7.2] - Hop to as a popup menu [Re: Mike G]
sirdude Offline
Enthusiast

Registered: 11/08/03
Posts: 490
Loc: SoCal
no, the hop to is within the html class. so you need to search for:

Code:
	// #######################################################################
	// Do login - Logs the user on
	// #######################################################################


and add just above it, the hop_to function. Step 1 had a typo in the Find:

---
---

Bad copy/paste on my part. Its all updated now..

Matter of fact, hop_to essentially obsoletes jump_box and that routine could be deleted. I chose not to for this mod, just in case it might be needed somewhere else.
_________________________

Top
#314865 - 07/21/07 10:16 PM Re: [7.2] - Hop to as a popup menu [Re: sirdude]
Rose Offline
Power User

Registered: 09/29/06
Posts: 76
Oh good ... I tried it three times and got the same error every time. Thanks for updating it SD - will try again. smile

Thanks too for these great mods. You guys who do these mods are fabulous. I can't write code (except HTML) to save my life!

Top
#314868 - 07/21/07 11:05 PM Re: [7.2] - Hop to as a popup menu [Re: Rose]
Gizmo Offline

Wizard

Registered: 01/10/00
Posts: 5354
Loc: Portland, OR, USA
It's you (and I) who make the feature request that deserve all of the thanks; if there was nothing to do, we'd have nothing to do wink
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design & Development President
UBB.Threads: My UBBSkins, UBB.Sitemaps

Top
#314871 - 07/22/07 12:20 AM Re: [7.2] - Hop to as a popup menu [Re: sirdude]
Mike G Offline
Newbie

Registered: 05/28/07
Posts: 11
Awesome! Works like a charm!

One thing I did notice is the hopto behavour when viewing a topic. I don't know if this is IE7 or what but when I click the "hopto" button I only get the current forum I'm in and there is no table around the pick list, just the current forum and the "Go" button. If I click any where but on the button or list the border shows up.

If I click the pick list I see all of the forums and if I select one the hopto box disappears and I'm still looking at the active topic.

Aw heck, here's a link! crazy

http://ubb7test.bobdunsire.com/ubbthreads.php?ubb=showflat&Number=24#Post24

This is our test site, the live site is still running v7.1.1


Top
#314872 - 07/22/07 12:26 AM Re: [7.2] - Hop to as a popup menu [Re: Rose]
Mike G Offline
Newbie

Registered: 05/28/07
Posts: 11
Quote:
Thanks too for these great mods. You guys who do these mods are fabulous. I can't write code (except HTML) to save my life!


I would also like to say THANKS for the hard work and effort you guys put into these mods.

I just got dropped into the deep end with UBB about a month ago with a decent sized site (11k members). I helped them move from Classic 6.7.0 on Winblows to 7.1.1 on Nix and away from a eastcoast datacenter to mine! smile

I'm currently running a few phpBB sites and after working with UBB I'm considering migrating them over to UBB.
thumbsup

Top
#314873 - 07/22/07 12:26 AM Re: [7.2] - Hop to as a popup menu [Re: Mike G]
sirdude Offline
Enthusiast

Registered: 11/08/03
Posts: 490
Loc: SoCal
looks like you did postlist fine... but the showflat looks like it's using the old jump_box stuff..

not sure why that is happening..

i will recheck the readme, but it looks like you almost got it, but like didn't delete something...

bleh.. dunno yet
_________________________

Top
#314874 - 07/22/07 12:29 AM Re: [7.2] - Hop to as a popup menu [Re: sirdude]
sirdude Offline
Enthusiast

Registered: 11/08/03
Posts: 490
Loc: SoCal
lol @ winblows..

i wish my OS (z80 operating system) got a title like that! i'd be a billionaire!

wink

ps: looks like (for whatever reason) you are enabling the old jump_box as the popup..

my guess is that you didn't modify showflat.inc.php to call hop_to and are still calling jump_box..

paste from readme:

Code:
Open: /scripts/showflat.inc.php

Find:

---
	// --------------------
	// Give the jumper box
	$jumpbox = $html -> jump_box($Board);
---

Replace with:

---
	// --------------------
	// Give the jumper box
	$jumpbox = $html -> hop_to(40);
---


:2c:
_________________________

Top
#314875 - 07/22/07 12:33 AM Re: [7.2] - Hop to as a popup menu [Re: sirdude]
Mike G Offline
Newbie

Registered: 05/28/07
Posts: 11
Originally Posted By: sirdude
looks like you did postlist fine... but the showflat looks like it's using the old jump_box stuff..

not sure why that is happening..

i will recheck the readme, but it looks like you almost got it, but like didn't delete something...

bleh.. dunno yet


Nope, it was me! Sorry about that! I was putting in Gizmo's AdminIP mod and was moving files around and forgot to re-add your bit.

Its working just fine now. smashpc

Top
#314876 - 07/22/07 12:34 AM Re: [7.2] - Hop to as a popup menu [Re: Mike G]
sirdude Offline
Enthusiast

Registered: 11/08/03
Posts: 490
Loc: SoCal
cool
_________________________

Top
#314878 - 07/22/07 02:39 AM Re: [7.2] - Hop to as a popup menu [Re: sirdude]
Gizmo Offline

Wizard

Registered: 01/10/00
Posts: 5354
Loc: Portland, OR, USA
i love being referanced in other peoples mod threads wink
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design & Development President
UBB.Threads: My UBBSkins, UBB.Sitemaps

Top
#314879 - 07/22/07 02:40 AM Re: [7.2] - Hop to as a popup menu [Re: Gizmo]
Gizmo Offline

Wizard

Registered: 01/10/00
Posts: 5354
Loc: Portland, OR, USA
You know, the only sugguestion that I have is to use the tdheader class for categories
_________________________
UBB.Dev - Where you too can render your UBB install completely useless...
UGN Security, Elite Web Gamers & VNC Web Design & Development President
UBB.Threads: My UBBSkins, UBB.Sitemaps

Top
#314880 - 07/22/07 07:01 AM Re: [7.2] - Hop to as a popup menu [Re: Gizmo]
Rose Offline
Power User

Registered: 09/29/06
Posts: 76
Ok, I got it to work, but the "40" width doesn't change when I change it in the scripts. And my subforums are not showing.

I was so careful, and was real pleased when it worked, but looks like I've done something wrong again. frown

Top
#314881 - 07/22/07 07:11 AM Re: [7.2] - Hop to as a popup menu [Re: Rose]
Rose Offline
Power User

Registered: 09/29/06
Posts: 76
Here's a screencap:



I change the menu width in four places, right?

1 place in postlist.inc.php
1 place in showflat.inc.php
2 places in ubbthreads.inc.php


Top
Page 1 of 3 1 2 3 >



Moderator:  sirdude 
Latest Posts
[7.2.1] - Naked shoutbox
by bellaonline
05/05/12 05:00 PM
[7.x] Stop Forum Spam Integration v0.4
by bellaonline
05/05/12 03:53 PM
Shout Box

(Views)Popular Topics
Known public proxy servers 1689885
Integrated Index Page (IIP) 5.3.1 555705
Finished-[6.5.2] Games Arcade Deluxe v1.9 501236
Integrated Index Page (IIP) 5.1.1 415112
TLD Bv2.1 Released - Threads Links Directory 396822
[6.0x] Who's Online 4.0.0 [Finished] 389412
Finished-[6.5.1] Integrated Index Page (IIP) 6.5 330423
Q & A 298663
Slash UBB 266936
[6.3.x] [beta] Hit Hack 2.0 227970
Forum Stats
13621 Members
59 Forums
37191 Topics
295716 Posts

Max Online: 686 @ 06/28/07 07:04 AM

 

 

 
fusionbb message board php hacks